#ifndef __LEAGUE_H__
#define __LEAGUE_H__

#include "population.h"
#include <stdio.h>
#include <list>

class League
{
	public:
		League(Population &pro, Population &anti);
	private:		
		int numberofplayers;
		
		/** reused for optimization **/
		static int turn;
		static int p1act;
		static int p2act;
		static int p1prevact[5];  // before n turn ( 0 = this turn)
		static int p2prevact[5];
		static int p1score;
		static int p2score;
		static int p1prevscore[5];
		static int p2prevscore[5];	
		static float p1avscore;
		static float p2avscore;
		static int error1;
		static int error2;

		int getaction(std::list<Decision> &rules,int turn,int* myactprev,int* youractprev,int* myscoreprev,int* yourscoreprev,
		float myavscore,float youravscore);

		void versus(std::list<Decision> &, std::list<Decision>&);
	
	
};


#endif
